Skip to content

Conversation

@SarahFrench
Copy link
Member

@SarahFrench SarahFrench commented Oct 20, 2025

This PR enables E2E testing with pluggable state storage:

  • Implements PSS support in the grpcwrap package, which is needed to allow provider-like code in Core to behave like it's a real separate provider plugin.
  • Implements an inmem and fs state store in the v6 version of terraform-provider-simple
    • Note: the filesystem PSS implementation doesn't include locking. In discussions we agreed that there was nothing to gain by implementing locking, as our E2E tests don't include more than one client.
    • If locking-specific testing is added in future then locking can be implemented then.
  • Adds E2E tests using the two PSS implementations, showing an init followed by an apply command.

Target Release

N/A

Rollback Plan

  • If a change needs to be reverted, we will roll out an update to the code within 7 days.

Changes to Security Controls

Are there any changes to security controls (access controls, encryption, logging) in this pull request? If so, explain.

CHANGELOG entry

  • This change is user-facing and I added a changelog entry.
  • This change is not user-facing.

@SarahFrench SarahFrench added the no-changelog-needed Add this to your PR if the change does not require a changelog entry label Oct 20, 2025
@SarahFrench SarahFrench changed the title PSS : Add inmem state storage implementation to the builtin terraform provider PSS : Add inmem state storage implementation to the builtin terraform provider, update grpcwrap package, use PSS implementation in E2E test Oct 24, 2025
@SarahFrench SarahFrench force-pushed the pss/add-builtin-inmem-state-storage-implementation branch from a4887d9 to ef6dc39 Compare October 24, 2025 11:04
@SarahFrench SarahFrench force-pushed the pss/add-builtin-inmem-state-storage-implementation branch 2 times, most recently from 0f01ff6 to 2fadb1e Compare October 24, 2025 11:38
@SarahFrench SarahFrench changed the title PSS : Add inmem state storage implementation to the builtin terraform provider, update grpcwrap package, use PSS implementation in E2E test PSS : Add fs and inmem state storage implementationd to the builtin simplev6 provider, update grpcwrap package, use PSS implementation in E2E test Oct 30, 2025
@SarahFrench SarahFrench force-pushed the pss/add-builtin-inmem-state-storage-implementation branch from 727ae19 to 8f77b19 Compare November 3, 2025 11:05
…tations, pass through requests to matching store based on type name.
… implementation; add embeddable unimplementedProviderInterface struct
…orm provider. Stop people using it unless TF_ACC is set.
…ther work to allow PSS to be used with other commands.
This provider is not accessible to users so it's unnecessary.
Seeing as I was in this part of the code during this branch's work
Comment on lines +108 to +110
Capabilities: providers.StateStoreClientCapabilities{
ChunkSize: DefaultStateStoreChunkSize,
},
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I realised that we never sent the default chunk size data from Core to the provider at the start of chunk size negotiation 😬

@SarahFrench SarahFrench force-pushed the pss/add-builtin-inmem-state-storage-implementation branch from 8f77b19 to 316d5b5 Compare November 6, 2025 12:40
@SarahFrench SarahFrench marked this pull request as ready for review November 6, 2025 15:11
@SarahFrench SarahFrench requested a review from a team as a code owner November 6, 2025 15:11
@SarahFrench SarahFrench changed the title PSS : Add fs and inmem state storage implementationd to the builtin simplev6 provider, update grpcwrap package, use PSS implementation in E2E test PSS : Add fs and inmem state storage implementations to the builtin simplev6 provider, update grpcwrap package, use PSS implementation in E2E test Nov 7, 2025
Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks pretty good, I left mostly minor comments and questions in-line but stand ready to approve once answered/addressed.

Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, looking forward to using this to build out more E2E tests! 👍🏻

@SarahFrench SarahFrench merged commit f2818db into main Nov 11, 2025
9 checks passed
@SarahFrench SarahFrench deleted the pss/add-builtin-inmem-state-storage-implementation branch November 11, 2025 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog-needed Add this to your PR if the change does not require a changelog entry

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants